fix: task assignee resolution for composer short mentions#96500
Conversation
Codecov Report❌ Looks like you've decreased code coverage for some files. Please write tests to increase, or at least maintain, the existing level of code coverage. See our documentation here for how to interpret this table.
|
adeba98 to
837aac2
Compare
837aac2 to
b3e0ee8
Compare
|
@codex review |
|
Codex Review: Didn't find any major issues. 🚀 Reviewed commit: ℹ️ About Codex in GitHubCodex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback". |
Since 4688d4e the composer passed useShortMentionsList's bare usernames into addDomainToShortMention, which checks full logins - the membership test could never match, so `[] @name Task title` created an unassigned task with the mention prefixed to the title. Feed the canonical addDomainToShortMention the full logins list from PersonalDetailsUtils instead and drop the personal-details render subscriptions from useComposerSubmit. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
b3e0ee8 to
1268d18
Compare
|
@marcochavezf Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Reviewer Checklist
Screenshots/VideosAndroid: HybridApp2026-07-21.15.44.00.movAndroid: mWeb Chrome2026-07-21.15.34.17.moviOS: HybridApp2026-07-21.15.44.00.moviOS: mWeb Safari2026-07-21.15.34.17.movMacOS: Chrome / Safari2026-07-21.15.24.34.mov |
|
LGTM! |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚧 mountiny has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.4.42-0 🚀
|
|
🤖 Help site review: no changes required. I reviewed the changes in this PR against the help articles under This is a bug fix that restores assignee resolution for the composer task shorthand ( The only task help article, Since no documented behavior changed, I did not create a draft docs PR. @adhorodyski, if you'd like the |
Explanation of Change
Creating a task with a short mention (
[] @name Task title) has not assigned the task since July 2025 (4688d4e). The composer passed bare usernames (name) intoaddDomainToShortMention, which checks full logins (name@domain.com). This check never matched, so the task was created unassigned with@nameleft in the title.The fix feeds
addDomainToShortMentionthe full logins list, via a newgetAllPersonalDetailLogins()inPersonalDetailsUtils, and looks up the assignee with the existinggetPersonalDetailByEmail.Both reads happen at submit time, so the composer input and send button no longer subscribe to the personal details collection on render.
Fixed Issues
$ #96612
PROPOSAL:
Tests
[] @coworker Some task(short mention, without the domain).[] @nosuchuser Some taskand verify the task is created unassigned, titled@nosuchuser Some task.Offline tests
Same as Tests. Task creation is optimistic and works offline.
QA Steps
Same as tests.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari